import { EventEmitter } from "./event_emitter";

class Model extends EventEmitter implements IModel {

  // the values of _serviceUrl must be set using the ModelSettings decorator
  private _serviceUrl: string;

  constructor(metiator: IMediator) {
    super(metiator);
  }

  // must be implemented by derived classes
  public initialize() {
    throw new Error('Model.prototype.initialize() is abstract and must implemented.');
  }

  // must be implemented by derived classes
  public dispose() {
    throw new Error('Model.prototype.dispose() is abstract and must implemented.');
  }
}

export { Model };
